<!DOCTYPE html>
<html>
	<head>
		
		<title></title>
	</head>
	<body>
		<script>
        var arr=[1,34,"d",3,4,"im"];
		var n=parseInt(prompt("请输入需要删除数据的下标："));
	    for(;n<arr.length-1;n++)
		{
			arr[n]=arr[n+1];
		}
		arr.length--;
		document.write("删除指定数据后的数组为：");

		for(var i=0;i<arr.length;i++)
		{
		document.write(arr[i]+",");
		}
		</script>
	</body>
</html>